﻿<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>告别石器时代|从石器时代的浏览器回到未来</title>
    <script type="text/javascript" src="~/Common/js/jquery-1.10.2.min.js"></script>
</head>
<body>
    <div class="nav">
        <div class="inner-center">
            <div class="logo"><img src="#" class="logo" id="logo" /></div>
            <div class="content-head">温馨提示：</div>
            <div class="content">您当前的浏览器版本过低，<span id="version"></span>存在安全风险，请尽快升级浏览器，再访问本网站。</div>
        </div>
    </div>
    <div>
        <div class="inner-center">
            <div class="main-background">
                <div class="left">
                    <img src="/Common/images/computer.png" alt="">
                    <div class="title">官方下载更新通道</div>
                </div>
                <div class="middle"></div>
                <div class="right">
                    <ul>
                        <li>
                            <img src="/Common/images/chrome.png" alt="">
                            <div>谷歌浏览器</div>
                            <a href="http://sw.bos.baidu.com/sw-search-sp/software/1e5d43b6599f5/ChromeStandalone_64.0.3282.119_Setup.exe">点击下载</a>
                        </li>
                        <li>
                            <img src="/Common/images/firefox.png" alt="">
                            <div>火狐浏览器</div>
                            <a href="http://www.firefox.com.cn/">点击下载</a>
                        </li>
                        <li>
                            <img src="/Common/images/IE.png" alt="">
                            <div>IE浏览器</div>
                            <a href="https://support.microsoft.com/zh-cn/help/17621/internet-explorer-downloads">点击下载</a>
                        </li>
                    </ul>
                </div>
            </div>
            <div><br /></div>
            <div class="main-background">
                <div class="left">
                    <img src="/Common/images/download.png" alt="">
                    <div class="title">本地下载更新通道</div>
                </div>
                <div class="middle"></div>
                <div class="right">
                    <ul>
                        <li>
                            <img src="/Common/images/chrome.png" alt="">
                            <div>谷歌浏览器</div>
                            <a href="#" id="chrome">点击下载</a>
                        </li>
                        <li>
                            <img src="/Common/images/firefox.png" alt="">
                            <div>火狐浏览器</div>
                            <a href="#" id="firefox">点击下载</a>
                        </li>
                        <li>
                            <img src="/Common/images/IE.png" alt="">
                            <div>IE浏览器</div>
                            <a href="#" id="ie">点击下载</a>
                        </li>
                    </ul>
                </div>
            </div>
        </div>
    </div>
</body>

</html>
<style>
    * {
        margin: 0;
        padding: 0;
    }

    .nav {
        height: 50px;
        margin: 40px 0 10px 0;
    }

    .inner-center {
        width: 1000px;
        margin: 0px auto;
    }

    .nav .logo {
        float: left;
        width: 200px;
        height: 50px;
        background-color: rgb(43, 174, 226);
    }

    .nav .content-head {
        float: left;
        width: 15%;
        height: 100%;
        font-size: 25px;
        text-align: right;
    }

    .nav .content {
        float: right;
        width: 65%;
        text-align: left;
        color: #e94126;
        font-size: 20px;
    }

    .main-background {
        height: 250px;
        width: 1000px;
        background-color: #f0f8ed;
    }

        .main-background .left {
            float: left;
            width: 200px;
            height: 250px;
            background-color: #87c309;
            text-align: center;
        }

            .main-background .left img {
                width: 160px;
                height: 160px;
                margin-top: 20px;
            }

            .main-background .left .title {
                float: left;
                width: 200px;
                height: 50px;
                text-align: center;
                color: white;
            }

        .main-background .middle {
            float: left;
            width: 0;
            height: 0;
            margin-top: 110px;
            border-style: solid;
            border-width: 15px 0 15px 20px;
            border-color: transparent transparent transparent #87c309;
        }

        .main-background .right ul {
            list-style: none;
        }

            .main-background .right ul li {
                float: left;
                width: 200px;
                margin-top: 20px;
                margin-left: 40px;
                text-align: center;
            }

                .main-background .right ul li img {
                    width: 140px;
                    height: 140px;
                }

                .main-background .right ul li a {
                    display: block;
                    text-decoration-line: none;
                    text-decoration-color: black;
                    margin: 10px auto;
                    color: white;
                    width: 180px;
                    height: 30px;
                    line-height: 30px;
                    background-color: #87c309;
                    text-align: center;
                }
</style>
<script>
   // $.post(".ashx", { dictye: "browser" }, function (res) { });
    var userAgent = navigator.userAgent;
    if (userAgent.indexOf("compatible") > -1 && userAgent.indexOf("MSIE 10.0") > -1) {
        //IE 10.0
        document.getElementById('version').innerHTML = "为IE 10.0，";
        console.log("IE 10.0");
    } else if (userAgent.indexOf("compatible") > -1 && userAgent.indexOf("MSIE 9.0") > -1) {
            //IE 9.0
            document.getElementById('version').innerHTML = "为IE 9.0，";
            console.log("IE 9.0");
    } else if (userAgent.indexOf("compatible") > -1 && userAgent.indexOf("MSIE 8.0") > -1) {
        //IE 8.0
        document.getElementById('version').innerHTML = "为IE 8.0，";
        console.log("IE 8.0");
    } else if (userAgent.indexOf("compatible") > -1 && userAgent.indexOf("MSIE 7.0") > -1) {
        //IE 7.0
        document.getElementById('version').innerHTML = "为IE 7.0，";
        console.log("IE 7.0");
    } else if (userAgent.indexOf("compatible") > -1 && userAgent.indexOf("MSIE 5.0") > -1) {
        //IE 5.0不能实现
        document.getElementById('version').innerHTML = "为IE 5.0，";
        console.log("IE 5.0");
    }
    //调接口
    $.post("api/free_value/get", { key: "browsers" }, function (res) {
        if (res.status == 10000) {
            $("#chrome").attr("href", JSON.parse(res.data.google.value).url);   
            $("#firefox").attr("href", JSON.parse(res.data.firefox.value).url);
            $("#ie").attr("href", JSON.parse(res.data.ie.value).url);
        } else {
            //在本地服务器放置固定浏览器提供下载，将链接赋给对应的按钮
        }
    });
    $.post("api/datadictionary/dictionary_tree", { typeName:"index_logo" }, function (res) {
        if (res.status == 10000) {
            $("#logo").attr("src", res.data.children[0].logo[0].url);
        } else {
            //在本地服务器固定位置放置占位logo
        }
    })
</script>